<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
     xmlns:p="http://primefaces.org/ui"
      
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">
    <h:head>
        <title>What did I Share¿?</title>
        <h:outputStylesheet name="css/jsfcrud.css"/>
    </h:head>
    <h:body>
        <h2>My Shares</h2>
        <p:dataList value="#{mySharesDataListBean.getMySharesList()}" var="share" type="ordered" >
            <p:fieldset legend="#{share.name}" toggleable="false" toggleSpeed="500">
                <h5>#{share.description}</h5>
                Date: #{share.startDate}
                <br />
                Budget: #{share.budget}
                <br/>
                Place: #{share.place}
                <br />
                Who is invited?
                <p:dataList value="#{share.invitedUsers}" var="user" >
                    #{user.firstName} #{user.lastName}
                </p:dataList>
                And who is gonna attend?
                <p:dataList value="#{share.acceptedUsers}" var="user" >
                    #{user.firstName} #{user.lastName}
                </p:dataList>
            </p:fieldset>
            <br/>
        </p:dataList>
    </h:body>
</html>

